Data Link_ Overview & framing.md (1073B)
1 +++ 2 title = "Data Link: Overview & framing" 3 +++ 4 5 # Data Link: Overview & framing 6 The layer: 7 8 - Transfers frames over a single link 9 - groups bits into frames 10 - provides services to network layer 11 - regulates data flow 12 - handles transmission errors 13 14 Possible services 15 16 - unacknowledged connectionless (no connection or error recovery) — e.g. ethernet 17 - acknowledged connectionless (frame is resent if needed) — e.g. 802.11 WiFi 18 - acknowledged connection-oriented (conn. established, only for unreliable connections) 19 20 **Framing** 21 22 frames — parts of bit stream with a checksum (computed when sent, recomputed to check for correctness when received) 23 24 Framing methods 25 26 - byte count 27 - first byte is length of frame 28 - problem is that if length gets fucked up, so rest of data 29 - byte stuffing 30 - contain a flag byte to delimit frames 31 - flag byte at end, flag byte at start 32 - need something that isn't used in data (or escaping) 33 - bit stuffing 34 - like byte stuffing, but smaller 35 - bit pattern instead of flag byte 36 - single bit instead of flag byte